﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace FallingWordsGame
{
    // Point in 2D coordinates
    public struct Coords
    {
        public int X { get; private set; }

        public int Y { get; private set; }

        public Coords(int X, int Y)
            : this()
        {
            this.X = X;
            this.Y = Y;
        }

        public static Coords operator +(Coords a, Coords b)
        {
            return new Coords(a.X + b.X, a.Y + b.Y);
        }

        public static Coords operator -(Coords a, Coords b)
        {
            return new Coords(a.X - b.X, a.Y - b.Y);
        }

        public override string ToString()
        {
            return string.Format("[{0} {1}]", this.X, this.Y);
        }

    }
}
